<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
    <%@taglib prefix="s" uri="/struts-tags" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>商品修改页面</title>
<link href="css/jimu.css" type="text/css" rel="stylesheet">
<!-- 基于网页地址条寻址 非目录寻址 -->

</head>
<body>
<!-- 头部包含文件 -->
<%@include file="../common/head.jsp" %>
<table class="main">
	<tr>
		<td style="width:180px;vertical-align:top;">
			<%@include file="../common/menu.jsp" %>	
		</td>
		<td style="vertical-align:top;padding:20px">
			<p>修改商品信息：（*为必填项）</p>
				<s:form action="modiProd.action" method="post" enctype="multipart/form-data">
					
					  		<%--  <input type="hidden" name="product.productid" value="<s:property value="product.productid"/>"> --%>
					  		 <s:hidden name="product.productid"/>
					  						  	
							 <s:doubleselect 
							label="类型选择" cssStyle="width:100px"
							
							list="superList"
							name="product.subtype.supertype.supertypeid"
							listKey="supertypeid"
							listValue="typename"
							
							doubleList="subtypes" 
							doubleName="product.subtype.subtypeid"
							doubleListKey="subtypeid"
							doubleListValue="subtypename"
							/>
					   <td>商品属性：</td>
						 <s:iterator value="product.productAttrs">
					   <td><s:property value="attr.attrname"/>.<s:property value="attr.attrvalue"/>.<s:property value="attrvalue"/></td>
					     </s:iterator>
							
						<s:select list="product.subtype.attrs" name="productAttr.attr.attrid" listKey="attrid" listValue="attrname" label="属性"/>
						<s:textfield name="productAttr.attrvalue" label="商品属性"/>
						<input type="hidden" name="productAttr.product.productid" value="<s:property value="product.productid"/>">
							
						<s:textfield name="product.productname" key="prodname"/>
						
						<s:file name="photo" label="商品图片"/>
						
						<s:textfield key="prodp" name="product.price" required="true" requiredposition="left"/>
						
						<s:textfield key="prodnp" name="product.nowprice"  required="true" requiredposition="left"/>
	
						<s:textfield key="prodn" name="product.productNum" />

						<s:set name="host" value="#{1:'是',0:'否'}"/>
                        <s:radio list="#host" listKey="key" listValue="value" name="product.isHost" label="是否热销"/>
                        
						<s:submit value="提交"/>
						<s:reset value="重置"/>
				
				</s:form>
				
		</td>
	</tr>

</table>
<%@include file="../common/tail.jsp" %>
</body>
</html>